/**
 * @author liangxi
 * @since 2024/4/11
 */

#include "SoldOutState.h"
#include "../GumballMachine.h"

GumballMachine *SoldOutState::getMGumballMachine() const {
    return mGumballMachine;
}

void SoldOutState::setMGumballMachine(GumballMachine *mGumballMachine) {
    SoldOutState::mGumballMachine = mGumballMachine;
}

void SoldOutState::dispense() {
    std::cout << "No gumball dispensed\n";
}

void SoldOutState::turnCrank() {
    std::cout << "You turned, but there are no gumballs\n";
}

void SoldOutState::ejectQuarter() {
    std::cout << "You can't eject, you haven't inserted a quarter yet\n";
}

void SoldOutState::insertQuarter() {
    std::cout << "You can't insert a quarter, the machine is sold out\n";
}

std::string SoldOutState::toString() {
    return "sold out";
}
